package cn.gjh.bookmanager.service;

import cn.gjh.bookmanager.entity.Ebookentry;
import cn.gjh.bookmanager.mapper.EbookentryMapper;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import javax.annotation.Resource;
import java.util.List;
@Service
@Transactional
public class EbookentryServiceImpl implements EbookentryService {
    @Resource
    private EbookentryMapper ebookentryMapper;


    @Override
    public int delete(Integer id) {
        return ebookentryMapper.delete(id);
    }

    @Override
    public List<Ebookentry> queryEbookEntryList(Integer categroyid ,Integer starNum,Integer pageSize) {
        return ebookentryMapper.queryEbookEntryList(categroyid,starNum, pageSize);
    }

    @Override
    public int updateEbookentry(Ebookentry ebookentry) {
        return ebookentryMapper.updateEbookentry(ebookentry);
    }

    @Override
    public int insertEbookentry(Ebookentry ebookentry) {
        return ebookentryMapper.insertEbookentry(ebookentry);
    }
}
